package com.xiashitech.authservice.constants;

import lombok.Getter;

@Getter
public enum ResourceTypeEnum {
  DATABASE_SERVICE(ResourceTypeId.DATABASE_SERVICE,
      null, false),

  DATABASE(ResourceTypeId.DATABASE,
      DATABASE_SERVICE, false),

  DATABASE_SCHEMA(ResourceTypeId.DATABASE_SCHEMA,
      DATABASE, false),

  TABLE(ResourceTypeId.TABLE,
      DATABASE_SCHEMA, false),

  COLUMN(ResourceTypeId.COLUMN,
      TABLE, false);

  private final String id;

  private final ResourceTypeEnum parent;


  private final boolean scopeResource;

  ResourceTypeEnum(String id, ResourceTypeEnum parent, boolean scopeResource) {
      this.id = id;
      this.parent = parent;
      this.scopeResource = scopeResource;
  }
}
